#页面类：个人中心页
from selenium.webdriver.common.by import By

#导入基类
from utils.page_base import PageBase

class PageUser(PageBase):
    path_url="/ucenter/index"
    loc_h2=By.CSS_SELECTOR,"div.user_info > h2"

    def __init__(self,driver,base_url):
        PageBase.__init__(self,driver,base_url)

    #打开本网页
    def openUrl(self):
        self.open(PageUser.path_url)

    #获取h2标签的文本内容
    def getH2Text(self):
        return self.getEleTextOrAttr(PageUser.loc_h2)





